InitArray

Syntax: @InitArray [arrayname[, value]]

This command clears all the array elements of the array called arrayname. By default, string arrays are set to null and numeric arrays to zero. The optional value parameter can be used to set an alternative default value. When used without parameters, the InitArray command will clear ALL arrays and ALL non-attribute variables (i.e. all numeric and string Knowledge Explorer variables).

Arrays are automatically cleared at the start of a new Run. Note that the Clear command does NOT clear array variables or clear numeric and string Knowledge Explorer variables.

Examples

@InitArray

clears all arrays, numeric and string Knowledge Explorer variables

@InitArray StrArr

clears an array called StrArr

@InitArray StrArr, 'Empty'

sets all elements of an array StrArr to 'Empty'.

@InitArray NumArr, 999

sets all elements of a numeric array NumArr to 999.